import requests

c1_header = {
    'Cookie':'TrainingPlatform-sid=s%3Az6XvdFTP1LUq65jWx-qh4hfhHoJ5r6zs.ItR5gMeubEGZdjGMu8Qf3MwZsqIe%2BPtKna9ExhZfnig; local-state={%22_id%22:%225faa4ee5ecb26f72e70d2a7c%22%2C%22username%22:%22c1%22%2C%22email%22:%22c1%22%2C%22roles%22:[%22user%22]%2C%22isTainingUser%22:true%2C%22department%22:%22%E4%B8%8A%E6%B5%B7%E5%85%AC%E5%AE%89%E5%B1%80%22%2C%22isReset%22:true%2C%22isModifyPersonal%22:false}; XSRF-TOKEN=HxwHt2Yj-Wfhsxy53fv5qUbiEo2ScmVWyWPk',
    'X-XSRF-TOKEN':'HxwHt2Yj-Wfhsxy53fv5qUbiEo2ScmVWyWPk'
}

c2_header = {
    'Cookie':'TrainingPlatform-sid=s%3Az6XvdFTP1LUq65jWx-qh4hfhHoJ5r6zs.ItR5gMeubEGZdjGMu8Qf3MwZsqIe%2BPtKna9ExhZfnig; local-state={%22_id%22:%225faa4ee6ecb26f60e10d2a7e%22%2C%22username%22:%22c2%22%2C%22email%22:%22c2%22%2C%22roles%22:[%22user%22]%2C%22isTainingUser%22:true%2C%22department%22:%22%E4%B8%8A%E6%B5%B7%E5%85%AC%E5%AE%89%E5%B1%80%22%2C%22isReset%22:true%2C%22isModifyPersonal%22:false}; XSRF-TOKEN=R5s5pxY9-hV0u2L02ZqxIeOiFxPbLuP8QXJw',
    'X-XSRF-TOKEN':'R5s5pxY9-hV0u2L02ZqxIeOiFxPbLuP8QXJw'
}

# response = requests.request("GET", "http://172.16.60.14/testPaper/detail?_id=5fbc9a24ba155a5b4e87ff03&forTraining=true", headers = header)
response = requests.request("GET", "http://172.16.60.14/training/question/detail?trainingId=5fd314a79a671e3cae7c7416&questionId=5fd314949a671ee22a7c73e7", headers = c1_header)

response1 = requests.request("GET", "http://172.16.60.14/training/answerAnalysis?skip=0&limit=10&trainingId=5fd314a79a671e3cae7c7416", headers = c1_header)

print("回答的答案   " + response.json()['answer'])

print("得分   " + str(response1.json()['questions'][1]['scoreOfAnswer']), "状态   " + str(response1.json()['questions'][1]['status']))